#ifndef OBJECTHOOK_HPP
#define OBJECTHOOK_HPP

#include <rootevent.pb.h>
#include <tdigievent.pb.h>
#include <tdstevent.pb.h>
#include <tevtheader.pb.h>
#include <tevtrecobject.pb.h>
#include <thltevent.pb.h>
#include <tmcevent.pb.h>
#include <ttrigevent.pb.h>
#include <ttag.pb.h>
#include <TEvtHeader.h>
#include <TEvtRecObject.h>
#include <TDstEvent.h>
#include <TDigiEvent.h>
#include <THltEvent.h>
#include <TMcEvent.h>
#include <TTrigEvent.h>
#include <TTag.h>

class ObjectHook{
public:
    void objectToBuffer(const TEvtHeader *,bes3::TEvtHeader *);
    void objectToBuffer(const TEvtRecObject *, bes3::TEvtRecObject *);
    void objectToBuffer(const TDstEvent *,bes3::TDstEvent *);
    void objectToBuffer(const TDigiEvent *,bes3::TDigiEvent *);
    void objectToBuffer(const TTrigEvent *,bes3::TTrigEvent *);
    void objectToBuffer(const TMcEvent *,bes3::TMcEvent *);
    void objectToBuffer(const THltEvent *,bes3::THltEvent *);
    void objectToBuffer(const TTag *,bes3::TTag *);
    void objectToBuffer(const TEvtRecTrack *,bes3::TEvtRecTrack *);
    void objectToBuffer(const TEvtRecEvent *,bes3::TEvtRecEvent *);
    void objectToBuffer(const TEvtRecPrimaryVertex *,bes3::TEvtRecPrimaryVertex *);
    void objectToBuffer(const TEvtRecVeeVertex *,bes3::TEvtRecVeeVertex *);
    void objectToBuffer(const TEvtRecPi0 *,bes3::TEvtRecPi0 *);
    void objectToBuffer(const TEvtRecEtaToGG *,bes3::TEvtRecEtaToGG *);
    void objectToBuffer(const TEvtRecDTag *,bes3::TEvtRecDTag *);
    void objectToBuffer(const TRawData *,bes3::TRawData *);
    void objectToBuffer(const TMdcDigi *,bes3::TMdcDigi *);
    void objectToBuffer(const TEmcDigi *,bes3::TEmcDigi *);
    void objectToBuffer(const TTofDigi *,bes3::TTofDigi *);
    void objectToBuffer(const TMucDigi *,bes3::TMucDigi *);
    void objectToBuffer(const TLumiDigi *,bes3::TLumiDigi *);
    void objectToBuffer(const TEmcTrack *,bes3::TEmcTrack *);
    void objectToBuffer(const TMdcTrack *,bes3::TMdcTrack *);
    void objectToBuffer(const TTofTrack *,bes3::TTofTrack *);
    void objectToBuffer(const TMucTrack *,bes3::TMucTrack *);
    void objectToBuffer(const TMdcDedx *,bes3::TMdcDedx *);
    void objectToBuffer(const TExtTrack *,bes3::TExtTrack *);
    void objectToBuffer(const TMdcKalTrack *,bes3::TMdcKalTrack *);
    void objectToBuffer(const THltInf *,bes3::THltInf *);
    void objectToBuffer(const TDstHltInf *,bes3::TDstHltInf *);
    void objectToBuffer(const THltRaw *,bes3::THltRaw *);
    void objectToBuffer(const TMdcMc *,bes3::TMdcMc *);
    void objectToBuffer(const TEmcMc *,bes3::TEmcMc *);
    void objectToBuffer(const TTofMc *,bes3::TTofMc *);
    void objectToBuffer(const TMucMc *,bes3::TMucMc *);
    void objectToBuffer(const TMcParticle *,bes3::TMcParticle *);
    void objectToBuffer(const TTrigData *,bes3::TTrigData *);
    void objectToBuffer(const TObject *,google::protobuf::Message *);
    void bufferToObject(const bes3::TEvtHeader *,TEvtHeader *);
    void bufferToObject(const bes3::TEvtRecObject *,TEvtRecObject *);
    void bufferToObject(const bes3::TDstEvent *,TDstEvent *);
    void bufferToObject(const bes3::TDigiEvent *,TDigiEvent *);
    void bufferToObject(const bes3::TTrigEvent *,TTrigEvent *);
    void bufferToObject(const bes3::TMcEvent *,TMcEvent *);
    void bufferToObject(const bes3::THltEvent *,THltEvent *);
    void bufferToObject(const bes3::TTag *,TTag *);
    void bufferToObject(const bes3::TEvtRecTrack *,TEvtRecTrack *);
    void bufferToObject(const bes3::TEvtRecEvent *,TEvtRecEvent *);
    void bufferToObject(const bes3::TEvtRecPrimaryVertex *,TEvtRecPrimaryVertex *);
    void bufferToObject(const bes3::TEvtRecEtaToGG *, TEvtRecEtaToGG *);
    void bufferToObject(const bes3::TEvtRecVeeVertex *,TEvtRecVeeVertex *);
    void bufferToObject(const bes3::TEvtRecPi0 *,TEvtRecPi0 *);
    void bufferToObject(const bes3::TEvtRecDTag *,TEvtRecDTag *);
    void bufferToObject(const bes3::TRawData *,TRawData *);
    void bufferToObject(const bes3::TMucDigi *,TMucDigi *);
    void bufferToObject(const bes3::TMdcDigi *,TMdcDigi *);
    void bufferToObject(const bes3::TEmcDigi *,TEmcDigi *);
    void bufferToObject(const bes3::TTofDigi *,TTofDigi *);
    void bufferToObject(const bes3::TLumiDigi *,TLumiDigi *);
    void bufferToObject(const bes3::TEmcTrack *,TEmcTrack *);
    void bufferToObject(const bes3::TMdcTrack *,TMdcTrack *);
    void bufferToObject(const bes3::TMucTrack *,TMucTrack *);
    void bufferToObject(const bes3::TTofTrack *,TTofTrack *);
    void bufferToObject(const bes3::TMdcDedx *,TMdcDedx *);
    void bufferToObject(const bes3::TExtTrack *,TExtTrack *);
    void bufferToObject(const bes3::TMdcKalTrack *,TMdcKalTrack *);
    void bufferToObject(const bes3::THltInf *,THltInf *);
    void bufferToObject(const bes3::TDstHltInf *,TDstHltInf *);
    void bufferToObject(const bes3::THltRaw *,THltRaw *);
    void bufferToObject(const bes3::TMdcMc *,TMdcMc *);
    void bufferToObject(const bes3::TMucMc *,TMucMc *);
    void bufferToObject(const bes3::TEmcMc *,TEmcMc *);
    void bufferToObject(const bes3::TTofMc *,TTofMc *);
    void bufferToObject(const bes3::TMcParticle *,TMcParticle *);
    void bufferToObject(const bes3::TTrigData *,TTrigData *);
    void bufferToObject(const google::protobuf::Message *,TObject *);
};


#endif // OBJECTHOOK_HPP
